home *** CD-ROM | disk | FTP | other *** search
- package sun.font;
-
- import java.awt.FontFormatException;
- import java.awt.geom.GeneralPath;
- import java.awt.geom.Point2D;
- import java.awt.geom.Rectangle2D;
- import java.io.File;
- import java.nio.ByteBuffer;
- import sun.java2d.Disposer;
-
- public abstract class FileFont extends PhysicalFont {
- protected boolean useJavaRasterizer = true;
- protected int fileSize;
- protected FileFontDisposer disposer;
- protected long pScaler;
- protected boolean checkedNatives;
- protected boolean useNatives;
- protected NativeFont[] nativeFonts;
- protected char[] glyphToCharMap;
-
- FileFont(String var1, Object var2) throws FontFormatException {
- super(var1, var2);
- }
-
- FontStrike createStrike(FontStrikeDesc var1) {
- if (!this.checkedNatives) {
- this.checkUseNatives();
- }
-
- return new FileFontStrike(this, var1);
- }
-
- protected boolean checkUseNatives() {
- this.checkedNatives = true;
- return this.useNatives;
- }
-
- protected abstract void close();
-
- abstract ByteBuffer readBlock(int var1, int var2);
-
- public boolean canDoStyle(int var1) {
- return true;
- }
-
- void setFileToRemove(File var1) {
- Disposer.addObjectRecord(this, new CreatedFontFileDisposerRecord(var1, (1)null));
- }
-
- static native void freeScaler(long var0);
-
- static synchronized native long getNullScaler();
-
- synchronized native StrikeMetrics getFontMetrics(long var1);
-
- synchronized native float getGlyphAdvance(long var1, int var3);
-
- synchronized native void getGlyphMetrics(long var1, int var3, Point2D.Float var4);
-
- synchronized native long getGlyphImage(long var1, int var3);
-
- synchronized native Rectangle2D.Float getGlyphOutlineBounds(long var1, int var3);
-
- synchronized native GeneralPath getGlyphOutline(long var1, int var3, float var4, float var5);
-
- synchronized native GeneralPath getGlyphVectorOutline(long var1, int[] var3, int var4, float var5, float var6);
-
- protected abstract long getScaler();
- }
-